import request from '@/utils/request'

// 创建用户充值
export function createUserRechargeInfo(data) {
  return request({
    url: '/system/user-recharge-info/create',
    method: 'post',
    data: data
  })
}

// 更新用户充值
export function updateUserRechargeInfo(data) {
  return request({
    url: '/system/user-recharge-info/update',
    method: 'put',
    data: data
  })
}

// 删除用户充值
export function deleteUserRechargeInfo(id) {
  return request({
    url: '/system/user-recharge-info/delete?id=' + id,
    method: 'delete'
  })
}

// 获得用户充值
export function getUserRechargeInfo(id) {
  return request({
    url: '/system/user-recharge-info/get?id=' + id,
    method: 'get'
  })
}

// 获得用户充值分页
export function getUserRechargeInfoPage(params) {
  return request({
    url: '/system/user-recharge-info/page',
    method: 'get',
    params
  })
}
// 导出用户充值 Excel
export function exportUserRechargeInfoExcel(params) {
  return request({
    url: '/system/user-recharge-info/export-excel',
    method: 'get',
    params,
    // responseType: 'blob'
  })
}

// 用户充值审核
export function approve(data) {
  return request({
    url: '/system/user-recharge-info/approve',
    method: 'put',
    data: data
  })
}

